//
//  GarbageCalssViewController.swift
//  Community
//
//  Created by MAC on 2019/8/2.
//  Copyright © 2019 ZKJ. All rights reserved.
//

import UIKit

class SWPTGarbageCalssViewController: UIViewController {

    override func viewDidLoad() {
        super.viewDidLoad()
        self.view.backgroundColor = UIColor.white
        self.title = ""
        let title = UILabel(frame: CGRect(x: 15, y: 5, width: 200, height: 30))
        title.font = UIFont.systemFont(ofSize: 25, weight: .medium)
        title.text = "分类"
        self.view.addSubview(title)
        let view = SWPTGarbageClassHeaderView(frame: CGRect(x: 0, y: 50, width: kScreenW, height: 500))
        view.selected = { [weak self] (selectedIndex) in
            self?.selected(selectedIndex)
        }
        self.view.addSubview(view)
     
        
    }

    private func selected(_ index: Int) {
        let listVC = SWPTGarbageListVC()
        listVC.index = index
        self.navigationController?.pushViewController(listVC, animated: true)
    }
    
    
}
